Set-PSDebug -Trace 1

function doc($Source){

   del index.html
   @"
<!DOCTYPE html>
<html lang="en">
<head>
   <meta charset="UTF-8">
   <title></title>
</head>
<body>
"@ | Add-Content -Path index.html

   pandoc -o 1.html $Source
   cat 1.html | Add-Content -Path index.html
   @"
</body>
</html>
"@ | Add-Content -Path index.html
   del 1.html

   @"
   mkdir -p /var/www/assets/
   :
"@ -replace "`r",""|ssh 'root@172.16.0.59'

   scp "index.html" "root@172.16.0.59:/var/www/"
   scp assets\11.png "root@172.16.0.59:/var/www/assets/"
   scp assets\1.png "root@172.16.0.59:/var/www/assets/"
   scp assets\58.png "root@172.16.0.59:/var/www/assets/"
   scp assets\21.png "root@172.16.0.59:/var/www/assets/"
   scp assets\1.xml "root@172.16.0.59:/var/www/assets/"
   scp assets\1.sql "root@172.16.0.59:/var/www/assets/"
   explorer "http://172.16.0.59:19120/index.html"
}

function manual{
   doc -Source "1.md"
}

function markdown{
   doc -Source "11.md"
}

if ($args.Length -gt 0){ &$args[0] $args[1..$args.Length] }
